package com.api.search;

import com.last.entity.City;
import com.last.entity.PageResult;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;

import java.util.List;
import java.util.Map;

//房间详情相关api
@Component
@FeignClient("homestay-search")
@RequestMapping("/homestaySearch")
public interface SearchApi {
    @PostMapping("/search")
    public PageResult searchByWhere(@RequestBody Map<String,String> searchMap);

    @GetMapping("gainCity")
    public List<City> gainCity();
}
